<!DOCTYPE html>
<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]>         <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <title>鼠标移入移出事件</title>
        <meta name="description" content="">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <style>
            .outer {
                width: 800px;
                height: 800px;
                background-color: rgb(194, 89, 89);
            }
            .middle {
                width: 600px;
                height: 600px;
                background-color: #fff;
            }
            .inner {
                width: 300px;
                height: 300px;
                background-color: rgb(188, 219, 103);
            }
        </style>
    </head>
    <body>
        <!--[if lt IE 7]>
            <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="#">upgrade your browser</a> to improve your experience.</p>
        <![endif]-->
        <div class="outer">
            <div class="middle">
                <div class="inner"></div>
            </div>
        </div>
        <script>
            var outer = document.getElementsByClassName("outer")[0];
            outer.addEventListener("mouseenter", function(e) {
                console.log(e.target.className);
                console.log(e.altKey);
            },false);
        </script>
    </body>
</html>